package com.kunbo.cn.controller.system;

import javax.servlet.http.HttpSession;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
import com.kunbo.cn.authority.RequiredPermission;
import com.kunbo.cn.entity.system.user.User;
import com.kunbo.cn.service.system.user.UserService;
import com.kunbo.cn.util.retu.CommonResult;

@Controller
public class LoginController {
	@Autowired
	private UserService userService;
	
	@RequestMapping("/dologin")
	@RequiredPermission("/dologin") // 权限注解
    @ResponseBody
    public Object dologin(User user,HttpSession session){
//        System.out.printf(user.toString());
//        //CommonResult cr =  userService.check(user.getName(), user.getPassword());
//        session.setAttribute("user", cr.getObj());
//        return cr;
		return null;
    }


}
